import { createBrowserRouter } from "react-router-dom";
import App from "../App";
import Home from '../props/home/Index'
const routers = createBrowserRouter([
    {
        path: '/',
        element: <App></App>,
        children: [
            { index: true, element: <Home></Home> },
            {
                path: '/home',
                lazy: async () => {
                    const { default: Home } = await import('../props/home/Index')
                    return {
                        element: <Home></Home>,
                    }
                }
            }
        ]
    },
    {
        path: '/Login',
        lazy: async () => {
            const { default: Login } = await import('../props/login/Index')
            return {
                element: <Login></Login>
            }
        }
    }
])
export default routers